home *** CD-ROM | disk | FTP | other *** search
/ Macwelt 2 / Macwelt DVD 2.cdr / Audio-Video-Multimedia / macos9 / Athena CL 1.0.13 / libATH / TImapTk.py < prev    next >
MacBinary  |  2002-03-15  |  10.3 KB  |  [TEXT/Pyth]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
1% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, Fri Mar 15 11:28:02 2002, modified Fri Mar 15 11:28:02 2002, creator 'Pyth', type ASCII, 9880 bytes "TImapTk.py" , at 0x2718 286 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% dearkID deark: macbinary default
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default
100% librempegprobeID NGC (Nintendo DSP Standard) (ngcdspstd) default (weak)


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[Pyth]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0a 54 49 6d 61 70 54 | 6b 2e 70 79 00 00 00 00 |..TImapT|k.py....|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 50 79 74 | 68 00 00 00 00 00 00 00 |.TEXTPyt|h.......|
|00000050| 00 00 00 00 00 26 98 00 | 00 01 1e b8 b7 d1 92 b8 |.....&..|........|
|00000060| b7 d1 92 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 35 e1 00 00 |........|....5...|
|00000080| 0d 0d 66 72 6f 6d 20 54 | 6b 69 6e 74 65 72 20 69 |..from T|kinter i|
|00000090| 6d 70 6f 72 74 20 2a 0d | 69 6d 70 6f 72 74 20 63 |mport *.|import c|
|000000a0| 6f 70 79 0d 69 6d 70 6f | 72 74 20 61 74 68 65 6e |opy.impo|rt athen|
|000000b0| 61 54 4b 0d 0d 66 6f 6e | 74 54 69 74 6c 65 20 3d |aTK..fon|tTitle =|
|000000c0| 20 61 74 68 65 6e 61 54 | 4b 2e 66 6f 6e 74 54 69 | athenaT|K.fontTi|
|000000d0| 74 6c 65 0d 66 6f 6e 74 | 54 65 78 74 20 20 3d 20 |tle.font|Text = |
|000000e0| 61 74 68 65 6e 61 54 4b | 2e 66 6f 6e 74 54 65 78 |athenaTK|.fontTex|
|000000f0| 74 0d 0d 43 4f 4c 4f 52 | 62 67 31 20 3d 20 61 74 |t..COLOR|bg1 = at|
|00000100| 68 65 6e 61 54 4b 2e 43 | 4f 4c 4f 52 62 67 31 20 |henaTK.C|OLORbg1 |
|00000110| 23 67 72 65 79 3a 20 67 | 72 6f 75 70 20 28 6d 65 |#grey: g|roup (me|
|00000120| 74 61 2d 72 6f 77 29 20 | 6c 61 62 65 6c 0d 43 4f |ta-row) |label.CO|
|00000130| 4c 4f 52 62 67 32 20 3d | 20 61 74 68 65 6e 61 54 |LORbg2 =| athenaT|
|00000140| 4b 2e 43 4f 4c 4f 52 62 | 67 32 20 23 61 6c 6d 6f |K.COLORb|g2 #almo|
|00000150| 73 74 2d 62 6c 61 63 6b | 3a 20 67 65 6e 65 72 61 |st-black|: genera|
|00000160| 6c 2d 62 6b 67 0d 43 4f | 4c 4f 52 62 67 33 20 3d |l-bkg.CO|LORbg3 =|
|00000170| 20 61 74 68 65 6e 61 54 | 4b 2e 43 4f 4c 4f 52 62 | athenaT|K.COLORb|
|00000180| 67 33 20 23 67 72 65 79 | 3a 20 73 69 6e 67 6c 65 |g3 #grey|: single|
|00000190| 2d 6c 69 6e 65 2c 20 62 | 72 69 67 68 74 65 73 74 |-line, b|rightest|
|000001a0| 20 63 6f 6c 6f 72 0d 43 | 4f 4c 4f 52 62 67 34 20 | color.C|OLORbg4 |
|000001b0| 3d 20 61 74 68 65 6e 61 | 54 4b 2e 43 4f 4c 4f 52 |= athena|TK.COLOR|
|000001c0| 62 67 34 20 23 67 72 65 | 79 3a 20 72 6f 77 2d 6c |bg4 #gre|y: row-l|
|000001d0| 65 76 65 6c 20 6c 61 62 | 65 6c 20 0d 43 4f 4c 4f |evel lab|el .COLO|
|000001e0| 52 62 67 35 20 3d 20 61 | 74 68 65 6e 61 54 4b 2e |Rbg5 = a|thenaTK.|
|000001f0| 43 4f 4c 4f 52 62 67 35 | 20 23 20 64 61 72 6b 65 |COLORbg5| # darke|
|00000200| 72 20 74 68 61 6e 20 62 | 67 32 0d 0d 43 4f 4c 4f |r than b|g2..COLO|
|00000210| 52 74 78 31 20 3d 20 61 | 74 68 65 6e 61 54 4b 2e |Rtx1 = a|thenaTK.|
|00000220| 43 4f 4c 4f 52 74 78 31 | 20 23 67 72 65 79 3a 20 |COLORtx1| #grey: |
|00000230| 67 72 6f 75 70 20 28 6d | 65 74 61 2d 72 6f 77 29 |group (m|eta-row)|
|00000240| 20 74 65 78 74 0d 43 4f | 4c 4f 52 74 78 32 20 3d | text.CO|LORtx2 =|
|00000250| 20 61 74 68 65 6e 61 54 | 4b 2e 43 4f 4c 4f 52 74 | athenaT|K.COLORt|
|00000260| 78 32 20 23 67 72 65 79 | 3a 20 72 6f 77 2d 6c 65 |x2 #grey|: row-le|
|00000270| 76 65 6c 20 74 65 78 74 | 0d 43 4f 4c 4f 52 74 78 |vel text|.COLORtx|
|00000280| 33 20 3d 20 61 74 68 65 | 6e 61 54 4b 2e 43 4f 4c |3 = athe|naTK.COL|
|00000290| 4f 52 74 78 33 20 23 64 | 61 72 6b 2d 72 6f 73 65 |ORtx3 #d|ark-rose|
|000002a0| 3a 20 62 75 74 74 6f 6e | 2d 6c 61 62 65 6c 20 74 |: button|-label t|
|000002b0| 65 78 74 0d 0d 0d 23 20 | 74 68 69 73 20 69 73 20 |ext...# |this is |
|000002c0| 74 68 65 20 64 61 74 61 | 20 73 74 72 75 63 74 75 |the data| structu|
|000002d0| 72 65 20 72 65 61 64 20 | 62 79 20 41 4f 6d 61 70 |re read |by AOmap|
|000002e0| 20 74 6f 20 70 72 6f 64 | 75 63 65 20 69 6d 61 67 | to prod|uce imag|
|000002f0| 65 2e 0d 74 69 4d 61 70 | 44 65 6d 6f 20 3d 20 7b |e..tiMap|Demo = {|
|00000300| 0d 27 74 65 78 74 75 72 | 65 41 27 20 3a 20 7b 27 |.'textur|eA' : {'|
|00000310| 74 52 61 6e 67 65 27 3a | 28 30 2c 38 29 2c 20 27 |tRange':|(0,8), '|
|00000320| 6d 75 74 65 53 74 61 74 | 75 73 27 3a 27 6d 75 74 |muteStat|us':'mut|
|00000330| 65 4f 46 46 27 2c 20 0d | 20 20 20 20 20 20 20 20 |eOFF', .| |
|00000340| 20 20 20 20 20 27 63 6c | 6f 6e 65 44 69 63 74 27 | 'cl|oneDict'|
|00000350| 3a 7b 27 63 6c 6f 6e 65 | 31 27 3a 20 32 2e 33 2c |:{'clone|1': 2.3,|
|00000360| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |. | |
|00000370| 20 20 20 20 20 20 20 20 | 20 20 20 27 63 6c 6f 6e | | 'clon|
|00000380| 65 32 27 3a 20 34 2c 0d | 20 20 20 20 20 20 20 20 |e2': 4,.| |
|00000390| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000003a0| 20 20 27 63 6c 6f 6e 65 | 33 27 3a 20 35 2c 7d 7d | 'clone|3': 5,}}|
|000003b0| 2c 0d 27 74 65 78 74 75 | 72 65 42 27 20 3a 20 7b |,.'textu|reB' : {|
|000003c0| 27 74 52 61 6e 67 65 27 | 3a 28 31 2c 36 29 2c 20 |'tRange'|:(1,6), |
|000003d0| 27 6d 75 74 65 53 74 61 | 74 75 73 27 3a 27 6d 75 |'muteSta|tus':'mu|
|000003e0| 74 65 4f 4e 27 2c 20 27 | 63 6c 6f 6e 65 44 69 63 |teON', '|cloneDic|
|000003f0| 74 27 3a 7b 7d 7d 2c 0d | 27 74 65 78 74 75 72 65 |t':{}},.|'texture|
|00000400| 43 27 20 3a 20 7b 27 74 | 52 61 6e 67 65 27 3a 28 |C' : {'t|Range':(|
|00000410| 2e 35 2c 32 30 29 2c 27 | 6d 75 74 65 53 74 61 74 |.5,20),'|muteStat|
|00000420| 75 73 27 3a 27 6d 75 74 | 65 4f 46 46 27 2c 27 63 |us':'mut|eOFF','c|
|00000430| 6c 6f 6e 65 44 69 63 74 | 27 3a 7b 7d 7d 2c 0d 27 |loneDict|':{}},.'|
|00000440| 74 65 78 74 75 72 65 44 | 27 20 3a 20 7b 27 74 52 |textureD|' : {'tR|
|00000450| 61 6e 67 65 27 3a 28 31 | 32 2c 31 35 29 2c 27 6d |ange':(1|2,15),'m|
|00000460| 75 74 65 53 74 61 74 75 | 73 27 3a 27 6d 75 74 65 |uteStatu|s':'mute|
|00000470| 4f 4e 27 2c 20 0d 20 20 | 20 20 20 20 20 20 20 20 |ON', . | |
|00000480| 20 20 20 27 63 6c 6f 6e | 65 44 69 63 74 27 3a 7b | 'clon|eDict':{|
|00000490| 27 63 6c 6f 6e 65 31 27 | 3a 20 2d 32 2e 33 2c 0d |'clone1'|: -2.3,.|
|000004a0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000004b0| 20 20 20 20 20 20 20 20 | 20 20 27 63 6c 6f 6e 65 | | 'clone|
|000004c0| 32 27 3a 20 2d 38 2e 33 | 2c 7d 7d 2c 0d 7d 0d 0d |2': -8.3|,}},.}..|
|000004d0| 0d 63 6c 61 73 73 20 41 | 4f 6d 61 70 43 61 6e 76 |.class A|OmapCanv|
|000004e0| 61 73 3a 0d 20 20 20 23 | 5f 77 20 3d 20 27 2e 27 |as:. #|_w = '.'|
|000004f0| 20 23 20 74 68 69 73 20 | 6d 61 6b 65 73 20 73 74 | # this |makes st|
|00000500| 64 4f 55 54 20 64 69 73 | 61 62 6c 65 64 0d 0d 20 |dOUT dis|abled.. |
|00000510| 20 20 64 65 66 20 5f 5f | 69 6e 69 74 5f 5f 28 73 | def __|init__(s|
|00000520| 65 6c 66 2c 20 6d 61 73 | 74 65 72 2c 20 61 6f 3d |elf, mas|ter, ao=|
|00000530| 4e 6f 6e 65 2c 20 62 61 | 72 48 45 49 47 48 54 3d |None, ba|rHEIGHT=|
|00000540| 31 30 2c 20 77 69 6e 57 | 49 44 54 48 3d 37 30 30 |10, winW|IDTH=700|
|00000550| 29 3a 0d 20 20 20 20 20 | 20 23 20 62 61 72 20 68 |):. | # bar h|
|00000560| 65 69 67 68 74 20 69 73 | 20 74 68 65 20 68 65 69 |eight is| the hei|
|00000570| 67 68 74 20 6f 66 20 74 | 65 78 74 75 72 65 20 69 |ght of t|exture i|
|00000580| 6e 20 70 69 78 65 6c 73 | 2e 20 74 68 65 20 74 6f |n pixels|. the to|
|00000590| 74 61 6c 20 68 65 69 67 | 68 74 20 6f 66 20 61 0d |tal heig|ht of a.|
|000005a0| 20 20 20 20 20 20 23 20 | 6f 66 20 61 20 77 69 6e | # |of a win|
|000005b0| 64 6f 77 20 69 73 20 64 | 65 74 65 72 6d 69 6e 65 |dow is d|etermine|
|000005c0| 64 20 62 79 20 74 68 65 | 20 6e 75 6d 62 65 72 20 |d by the| number |
|000005d0| 6f 66 20 74 65 78 74 75 | 72 65 73 20 20 20 20 20 |of textu|res |
|000005e0| 20 0d 20 20 20 20 20 20 | 69 66 20 61 6f 20 3d 3d | . |if ao ==|
|000005f0| 20 4e 6f 6e 65 3a 0d 20 | 20 20 20 20 20 20 20 20 | None:. | |
|00000600| 73 65 6c 66 2e 74 69 4d | 61 70 44 69 63 74 20 3d |self.tiM|apDict =|
|00000610| 20 74 69 4d 61 70 44 65 | 6d 6f 0d 20 20 20 20 20 | tiMapDe|mo. |
|00000620| 20 65 6c 73 65 3a 0d 20 | 20 20 20 20 20 20 20 20 | else:. | |
|00000630| 54 65 78 74 75 72 65 42 | 69 6e 20 3d 20 61 6f 2e |TextureB|in = ao.|
|00000640| 54 65 78 74 75 72 65 42 | 69 6e 0d 20 20 20 20 20 |TextureB|in. |
|00000650| 20 20 20 20 4d 75 74 65 | 4c 69 73 74 20 3d 20 61 | Mute|List = a|
|00000660| 6f 2e 4d 75 74 65 4c 69 | 73 74 0d 20 20 20 20 20 |o.MuteLi|st. |
|00000670| 20 20 20 20 54 65 78 74 | 75 72 65 43 6c 6f 6e 65 | Text|ureClone|
|00000680| 4f 62 6a 20 3d 20 61 6f | 2e 54 65 78 74 75 72 65 |Obj = ao|.Texture|
|00000690| 43 6c 6f 6e 65 4f 62 6a | 2e 74 63 44 69 63 74 0d |CloneObj|.tcDict.|
|000006a0| 20 20 20 0d 20 20 20 20 | 20 20 20 20 20 74 69 4d | . | tiM|
|000006b0| 61 70 44 69 63 74 20 3d | 20 7b 7d 20 23 63 6c 65 |apDict =| {} #cle|
|000006c0| 61 72 0d 20 20 20 20 20 | 20 20 20 20 66 6f 72 20 |ar. | for |
|000006d0| 74 69 4e 61 6d 65 20 69 | 6e 20 54 65 78 74 75 72 |tiName i|n Textur|
|000006e0| 65 42 69 6e 2e 6b 65 79 | 73 28 29 3a 0d 20 20 20 |eBin.key|s():. |
|000006f0| 20 20 20 20 20 20 20 20 | 20 74 69 4d 61 70 44 69 | | tiMapDi|
|00000700| 63 74 5b 74 69 4e 61 6d | 65 5d 20 3d 20 7b 7d 0d |ct[tiNam|e] = {}.|
|00000710| 20 20 20 20 20 20 20 20 | 20 20 20 20 74 69 4d 61 | | tiMa|
|00000720| 70 44 69 63 74 5b 74 69 | 4e 61 6d 65 5d 5b 27 74 |pDict[ti|Name]['t|
|00000730| 52 61 6e 67 65 27 5d 20 | 3d 20 54 65 78 74 75 72 |Range'] |= Textur|
|00000740| 65 42 69 6e 5b 74 69 4e | 61 6d 65 5d 2e 70 6d 74 |eBin[tiN|ame].pmt|
|00000750| 72 4f 62 6a 44 69 63 74 | 5b 27 74 52 61 6e 67 65 |rObjDict|['tRange|
|00000760| 27 5d 2e 73 74 61 74 69 | 63 52 61 6e 67 65 28 29 |'].stati|cRange()|
|00000770| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 69 66 20 |. | if |
|00000780| 74 69 4e 61 6d 65 20 69 | 6e 20 4d 75 74 65 4c 69 |tiName i|n MuteLi|
|00000790| 73 74 3a 0d 20 20 20 20 | 20 20 20 20 20 20 20 20 |st:. | |
|000007a0| 20 20 20 74 69 4d 61 70 | 44 69 63 74 5b 74 69 4e | tiMap|Dict[tiN|
|000007b0| 61 6d 65 5d 5b 27 6d 75 | 74 65 53 74 61 74 75 73 |ame]['mu|teStatus|
|000007c0| 27 5d 20 3d 20 27 6d 75 | 74 65 4f 4e 27 0d 20 20 |'] = 'mu|teON'. |
|000007d0| 20 20 20 20 20 20 20 20 | 20 20 65 6c 73 65 3a 0d | | else:.|
|000007e0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 74 | | t|
|000007f0| 69 4d 61 70 44 69 63 74 | 5b 74 69 4e 61 6d 65 5d |iMapDict|[tiName]|
|00000800| 5b 27 6d 75 74 65 53 74 | 61 74 75 73 27 5d 20 3d |['muteSt|atus'] =|
|00000810| 20 27 6d 75 74 65 4f 46 | 46 27 0d 20 20 20 20 20 | 'muteOF|F'. |
|00000820| 20 20 20 20 20 20 20 74 | 69 4d 61 70 44 69 63 74 | t|iMapDict|
|00000830| 5b 74 69 4e 61 6d 65 5d | 5b 27 63 6c 6f 6e 65 44 |[tiName]|['cloneD|
|00000840| 69 63 74 27 5d 20 3d 20 | 7b 7d 0d 20 20 20 20 20 |ict'] = |{}. |
|00000850| 20 20 20 20 20 20 20 69 | 66 20 74 69 4e 61 6d 65 | i|f tiName|
|00000860| 20 69 6e 20 54 65 78 74 | 75 72 65 43 6c 6f 6e 65 | in Text|ureClone|
|00000870| 4f 62 6a 2e 6b 65 79 73 | 28 29 3a 0d 20 20 20 20 |Obj.keys|():. |
|00000880| 20 20 20 20 20 20 20 20 | 20 20 20 66 6f 72 20 74 | | for t|
|00000890| 63 4e 61 6d 65 20 69 6e | 20 54 65 78 74 75 72 65 |cName in| Texture|
|000008a0| 43 6c 6f 6e 65 4f 62 6a | 5b 74 69 4e 61 6d 65 5d |CloneObj|[tiName]|
|000008b0| 2e 6b 65 79 73 28 29 3a | 0d 20 20 20 20 20 20 20 |.keys():|. |
|000008c0| 20 20 20 20 20 20 20 20 | 20 20 20 74 69 6d 65 53 | | timeS|
|000008d0| 68 69 66 74 20 3d 20 54 | 65 78 74 75 72 65 43 6c |hift = T|extureCl|
|000008e0| 6f 6e 65 4f 62 6a 5b 74 | 69 4e 61 6d 65 5d 5b 74 |oneObj[t|iName][t|
|000008f0| 63 4e 61 6d 65 5d 5b 30 | 5d 23 67 65 74 73 54 69 |cName][0|]#getsTi|
|00000900| 6d 65 53 68 69 66 74 0d | 20 20 20 20 20 20 20 20 |meShift.| |
|00000910| 20 20 20 20 20 20 20 20 | 20 20 74 69 4d 61 70 44 | | tiMapD|
|00000920| 69 63 74 5b 74 69 4e 61 | 6d 65 5d 5b 27 63 6c 6f |ict[tiNa|me]['clo|
|00000930| 6e 65 44 69 63 74 27 5d | 5b 74 63 4e 61 6d 65 5d |neDict']|[tcName]|
|00000940| 20 3d 20 74 69 6d 65 53 | 68 69 66 74 0d 20 20 20 | = timeS|hift. |
|00000950| 20 20 20 20 20 20 73 65 | 6c 66 2e 74 69 4d 61 70 | se|lf.tiMap|
|00000960| 44 69 63 74 20 3d 20 74 | 69 4d 61 70 44 69 63 74 |Dict = t|iMapDict|
|00000970| 0d 0d 20 20 20 20 20 20 | 73 65 6c 66 2e 74 6f 74 |.. |self.tot|
|00000980| 61 6c 54 69 6d 65 20 3d | 20 73 65 6c 66 2e 66 69 |alTime =| self.fi|
|00000990| 6e 64 54 6f 74 61 6c 54 | 69 6d 65 28 73 65 6c 66 |ndTotalT|ime(self|
|000009a0| 2e 74 69 4d 61 70 44 69 | 63 74 29 0d 0d 20 20 20 |.tiMapDi|ct).. |
|000009b0| 20 20 20 73 65 6c 66 2e | 6e 6f 45 6e 74 72 69 65 | self.|noEntrie|
|000009c0| 73 20 3d 20 6c 65 6e 28 | 73 65 6c 66 2e 74 69 4d |s = len(|self.tiM|
|000009d0| 61 70 44 69 63 74 2e 6b | 65 79 73 28 29 29 0d 20 |apDict.k|eys()). |
|000009e0| 20 20 20 20 20 66 6f 72 | 20 74 65 78 74 4e 61 6d | for| textNam|
|000009f0| 65 20 69 6e 20 73 65 6c | 66 2e 74 69 4d 61 70 44 |e in sel|f.tiMapD|
|00000a00| 69 63 74 2e 6b 65 79 73 | 28 29 3a 20 23 63 6f 75 |ict.keys|(): #cou|
|00000a10| 6e 74 20 63 6c 6f 6e 65 | 73 0d 20 20 20 20 20 20 |nt clone|s. |
|00000a20| 20 20 20 73 65 6c 66 2e | 6e 6f 45 6e 74 72 69 65 | self.|noEntrie|
|00000a30| 73 20 3d 20 73 65 6c 66 | 2e 6e 6f 45 6e 74 72 69 |s = self|.noEntri|
|00000a40| 65 73 2b 6c 65 6e 28 73 | 65 6c 66 2e 74 69 4d 61 |es+len(s|elf.tiMa|
|00000a50| 70 44 69 63 74 5b 74 65 | 78 74 4e 61 6d 65 5d 5b |pDict[te|xtName][|
|00000a60| 27 63 6c 6f 6e 65 44 69 | 63 74 27 5d 2e 6b 65 79 |'cloneDi|ct'].key|
|00000a70| 73 28 29 29 0d 20 20 20 | 20 20 20 73 65 6c 66 2e |s()). | self.|
|00000a80| 6e 6f 47 75 74 74 65 72 | 73 20 3d 20 73 65 6c 66 |noGutter|s = self|
|00000a90| 2e 6e 6f 45 6e 74 72 69 | 65 73 20 2b 20 31 0d 20 |.noEntri|es + 1. |
|00000aa0| 20 20 20 20 20 73 65 6c | 66 2e 6d 61 70 47 55 54 | sel|f.mapGUT|
|00000ab0| 54 45 52 20 20 20 20 20 | 20 20 3d 20 33 20 23 20 |TER | = 3 # |
|00000ac0| 69 6e 20 70 69 78 65 6c | 73 0d 20 20 20 20 20 20 |in pixel|s. |
|00000ad0| 73 65 6c 66 2e 65 6e 74 | 72 79 48 65 61 64 48 65 |self.ent|ryHeadHe|
|00000ae0| 69 67 68 74 20 3d 20 32 | 20 23 20 62 61 6e 64 20 |ight = 2| # band |
|00000af0| 61 74 20 74 6f 70 20 6f | 66 20 65 6e 74 72 79 20 |at top o|f entry |
|00000b00| 62 6c 6f 63 6b 73 0d 20 | 20 20 20 20 20 73 65 6c |blocks. | sel|
|00000b10| 66 2e 79 4d 61 72 67 69 | 6e 53 68 69 66 74 20 20 |f.yMargi|nShift |
|00000b20| 20 20 3d 20 31 38 20 23 | 65 6e 74 72 79 48 65 61 | = 18 #|entryHea|
|00000b30| 64 48 65 69 67 68 74 0d | 20 20 20 20 20 20 73 65 |dHeight.| se|
|00000b40| 6c 66 2e 78 4d 61 72 67 | 69 6e 53 68 69 66 74 20 |lf.xMarg|inShift |
|00000b50| 20 20 20 3d 20 31 30 30 | 20 23 6e 61 6d 65 73 20 | = 100| #names |
|00000b60| 6f 66 20 74 65 78 74 75 | 72 65 73 20 6f 6e 20 6c |of textu|res on l|
|00000b70| 65 66 74 0d 0d 20 20 20 | 20 20 20 23 20 74 68 69 |eft.. | # thi|
|00000b80| 73 20 63 61 6c 63 75 6c | 61 74 65 20 74 68 65 20 |s calcul|ate the |
|00000b90| 68 65 69 67 68 74 20 6f | 66 20 74 68 65 20 65 6e |height o|f the en|
|00000ba0| 74 69 72 65 20 77 69 6e | 64 6f 77 0d 20 20 20 20 |tire win|dow. |
|00000bb0| 20 20 61 6c 67 6f 48 65 | 69 67 68 74 20 3d 20 28 | algoHe|ight = (|
|00000bc0| 73 65 6c 66 2e 6e 6f 45 | 6e 74 72 69 65 73 20 2a |self.noE|ntries *|
|00000bd0| 20 62 61 72 48 45 49 47 | 48 54 29 20 2b 20 28 73 | barHEIG|HT) + (s|
|00000be0| 65 6c 66 2e 6e 6f 47 75 | 74 74 65 72 73 20 2a 20 |elf.noGu|tters * |
|00000bf0| 73 65 6c 66 2e 6d 61 70 | 47 55 54 54 45 52 29 20 |self.map|GUTTER) |
|00000c00| 2b 20 73 65 6c 66 2e 79 | 4d 61 72 67 69 6e 53 68 |+ self.y|MarginSh|
|00000c10| 69 66 74 0d 0d 20 20 20 | 20 20 20 73 65 6c 66 2e |ift.. | self.|
|00000c20| 77 69 6e 48 45 49 47 48 | 54 20 3d 20 61 6c 67 6f |winHEIGH|T = algo|
|00000c30| 48 65 69 67 68 74 20 23 | 31 32 30 20 23 20 31 32 |Height #|120 # 12|
|00000c40| 20 2a 20 6e 6f 45 6e 74 | 72 69 65 73 20 61 74 20 | * noEnt|ries at |
|00000c50| 6c 65 61 73 74 20 31 34 | 20 70 65 72 20 65 6e 74 |least 14| per ent|
|00000c60| 72 79 0d 20 20 20 20 20 | 20 69 66 20 77 69 6e 57 |ry. | if winW|
|00000c70| 49 44 54 48 20 3c 20 32 | 30 30 3a 0d 20 20 20 20 |IDTH < 2|00:. |
|00000c80| 20 20 20 20 20 73 65 6c | 66 2e 77 69 6e 57 49 44 | sel|f.winWID|
|00000c90| 54 48 20 3d 20 32 30 30 | 0d 20 20 20 20 20 20 65 |TH = 200|. e|
|00000ca0| 6c 69 66 20 77 69 6e 57 | 49 44 54 48 20 3e 20 33 |lif winW|IDTH > 3|
|00000cb0| 30 30 30 3a 0d 20 20 20 | 20 20 20 20 20 20 73 65 |000:. | se|
|00000cc0| 6c 66 2e 77 69 6e 57 49 | 44 54 48 20 3d 20 33 30 |lf.winWI|DTH = 30|
|00000cd0| 30 30 0d 20 20 20 20 20 | 20 65 6c 73 65 3a 0d 20 |00. | else:. |
|00000ce0| 20 20 20 20 20 20 20 20 | 73 65 6c 66 2e 77 69 6e | |self.win|
|00000cf0| 57 49 44 54 48 20 20 3d | 20 77 69 6e 57 49 44 54 |WIDTH =| winWIDT|
|00000d00| 48 20 20 23 36 30 30 20 | 23 0d 20 20 20 20 20 20 |H #600 |#. |
|00000d10| 0d 20 20 20 20 20 20 73 | 65 6c 66 2e 6d 61 70 48 |. s|elf.mapH|
|00000d20| 45 49 47 48 54 20 3d 20 | 73 65 6c 66 2e 77 69 6e |EIGHT = |self.win|
|00000d30| 48 45 49 47 48 54 20 2d | 20 73 65 6c 66 2e 79 4d |HEIGHT -| self.yM|
|00000d40| 61 72 67 69 6e 53 68 69 | 66 74 20 20 23 20 66 6f |arginShi|ft # fo|
|00000d50| 72 20 6b 65 79 0d 20 20 | 20 20 20 20 73 65 6c 66 |r key. | self|
|00000d60| 2e 6d 61 70 57 49 44 54 | 48 20 20 3d 20 73 65 6c |.mapWIDT|H = sel|
|00000d70| 66 2e 77 69 6e 57 49 44 | 54 48 20 20 2d 20 73 65 |f.winWID|TH - se|
|00000d80| 6c 66 2e 78 4d 61 72 67 | 69 6e 53 68 69 66 74 20 |lf.xMarg|inShift |
|00000d90| 20 23 20 66 6f 72 20 6e | 61 6d 65 73 0d 20 20 20 | # for n|ames. |
|00000da0| 20 20 20 0d 20 20 20 20 | 20 20 73 65 6c 66 2e 77 | . | self.w|
|00000db0| 69 64 74 68 41 6c 6c 47 | 75 74 74 65 72 73 20 3d |idthAllG|utters =|
|00000dc0| 20 73 65 6c 66 2e 6d 61 | 70 47 55 54 54 45 52 20 | self.ma|pGUTTER |
|00000dd0| 2a 20 73 65 6c 66 2e 6e | 6f 47 75 74 74 65 72 73 |* self.n|oGutters|
|00000de0| 0d 20 20 20 20 20 20 73 | 65 6c 66 2e 77 69 64 74 |. s|elf.widt|
|00000df0| 68 41 6c 6c 45 6e 74 72 | 69 65 73 20 3d 20 73 65 |hAllEntr|ies = se|
|00000e00| 6c 66 2e 6d 61 70 48 45 | 49 47 48 54 20 2d 20 73 |lf.mapHE|IGHT - s|
|00000e10| 65 6c 66 2e 77 69 64 74 | 68 41 6c 6c 47 75 74 74 |elf.widt|hAllGutt|
|00000e20| 65 72 73 0d 20 20 20 20 | 20 20 23 72 6f 75 6e 64 |ers. | #round|
|00000e30| 20 74 6f 20 6e 65 61 72 | 65 73 74 20 70 69 78 0d | to near|est pix.|
|00000e40| 20 20 20 20 20 20 69 66 | 20 73 65 6c 66 2e 6e 6f | if| self.no|
|00000e50| 45 6e 74 72 69 65 73 20 | 3e 20 30 3a 0d 20 20 20 |Entries |> 0:. |
|00000e60| 20 20 20 20 20 20 73 65 | 6c 66 2e 77 69 64 74 68 | se|lf.width|
|00000e70| 45 6e 74 72 79 20 3d 20 | 72 6f 75 6e 64 28 73 65 |Entry = |round(se|
|00000e80| 6c 66 2e 77 69 64 74 68 | 41 6c 6c 45 6e 74 72 69 |lf.width|AllEntri|
|00000e90| 65 73 2f 28 73 65 6c 66 | 2e 6e 6f 45 6e 74 72 69 |es/(self|.noEntri|
|00000ea0| 65 73 2b 30 2e 30 29 29 | 0d 20 20 20 20 20 20 65 |es+0.0))|. e|
|00000eb0| 6c 73 65 3a 0d 20 20 20 | 20 20 20 20 20 20 73 65 |lse:. | se|
|00000ec0| 6c 66 2e 77 69 64 74 68 | 45 6e 74 72 79 20 3d 20 |lf.width|Entry = |
|00000ed0| 30 0d 0d 0d 20 20 20 20 | 20 20 66 72 61 6d 65 20 |0... | frame |
|00000ee0| 3d 20 46 72 61 6d 65 28 | 6d 61 73 74 65 72 2c 20 |= Frame(|master, |
|00000ef0| 77 69 64 74 68 3d 73 65 | 6c 66 2e 77 69 6e 57 49 |width=se|lf.winWI|
|00000f00| 44 54 48 2c 20 68 65 69 | 67 68 74 3d 73 65 6c 66 |DTH, hei|ght=self|
|00000f10| 2e 77 69 6e 48 45 49 47 | 48 54 2c 20 62 64 3d 30 |.winHEIG|HT, bd=0|
|00000f20| 2c 20 0d 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |, . | |
|00000f30| 20 62 67 3d 27 23 30 30 | 30 30 30 30 27 2c 20 72 | bg='#00|0000', r|
|00000f40| 65 6c 69 65 66 3d 27 66 | 6c 61 74 27 29 0d 20 20 |elief='f|lat'). |
|00000f50| 20 20 20 20 66 72 61 6d | 65 2e 70 61 63 6b 28 66 | fram|e.pack(f|
|00000f60| 69 6c 6c 3d 27 62 6f 74 | 68 27 2c 20 70 61 64 79 |ill='bot|h', pady|
|00000f70| 3d 30 2c 20 70 61 64 78 | 3d 30 29 0d 0d 20 20 20 |=0, padx|=0).. |
|00000f80| 20 20 20 23 20 63 72 65 | 61 74 65 20 62 61 73 65 | # cre|ate base|
|00000f90| 20 63 61 6e 76 61 73 0d | 20 20 20 20 20 20 63 20 | canvas.| c |
|00000fa0| 3d 20 43 61 6e 76 61 73 | 28 66 72 61 6d 65 2c 20 |= Canvas|(frame, |
|00000fb0| 62 67 3d 27 23 30 30 30 | 30 30 30 27 2c 20 62 64 |bg='#000|000', bd|
|00000fc0| 3d 30 2c 20 77 69 64 74 | 68 3d 73 65 6c 66 2e 77 |=0, widt|h=self.w|
|00000fd0| 69 6e 57 49 44 54 48 2c | 20 0d 20 20 20 20 20 20 |inWIDTH,| . |
|00000fe0| 68 65 69 67 68 74 3d 73 | 65 6c 66 2e 77 69 6e 48 |height=s|elf.winH|
|00000ff0| 45 49 47 48 54 2c 20 68 | 69 67 68 6c 69 67 68 74 |EIGHT, h|ighlight|
|00001000| 74 68 69 63 6b 6e 65 73 | 73 3d 30 29 0d 20 20 20 |thicknes|s=0). |
|00001010| 20 20 20 63 2e 70 61 63 | 6b 28 66 69 6c 6c 3d 27 | c.pac|k(fill='|
|00001020| 62 6f 74 68 27 2c 20 70 | 61 64 79 3d 30 2c 20 70 |both', p|ady=0, p|
|00001030| 61 64 78 3d 30 29 20 0d | 0d 0d 20 20 20 20 20 20 |adx=0) .|.. |
|00001040| 23 20 6c 6d 61 72 67 69 | 6e 20 62 6c 6f 63 6b 3a |# lmargi|n block:|
|00001050| 20 6e 61 6d 65 73 20 61 | 72 65 20 64 72 61 77 6e | names a|re drawn|
|00001060| 20 6f 76 65 72 0d 20 20 | 20 20 20 20 63 2e 63 72 | over. | c.cr|
|00001070| 65 61 74 65 5f 72 65 63 | 74 61 6e 67 6c 65 28 30 |eate_rec|tangle(0|
|00001080| 2c 30 2c 73 65 6c 66 2e | 78 4d 61 72 67 69 6e 53 |,0,self.|xMarginS|
|00001090| 68 69 66 74 2c 73 65 6c | 66 2e 77 69 6e 48 45 49 |hift,sel|f.winHEI|
|000010a0| 47 48 54 2c 20 0d 20 20 | 20 20 20 20 66 69 6c 6c |GHT, . | fill|
|000010b0| 3d 43 4f 4c 4f 52 62 67 | 32 2c 20 6f 75 74 6c 69 |=COLORbg|2, outli|
|000010c0| 6e 65 3d 27 62 6c 61 63 | 6b 27 2c 20 77 69 64 74 |ne='blac|k', widt|
|000010d0| 68 3d 30 29 0d 0d 20 20 | 20 20 20 20 23 20 74 6f |h=0).. | # to|
|000010e0| 74 61 6c 20 74 69 6d 65 | 20 69 6e 20 75 70 70 65 |tal time| in uppe|
|000010f0| 72 20 6c 65 66 74 0d 20 | 20 20 20 20 20 74 6f 74 |r left. | tot|
|00001100| 61 6c 54 69 6d 65 53 74 | 72 20 3d 20 27 25 2e 31 |alTimeSt|r = '%.1|
|00001110| 66 27 25 20 28 73 65 6c | 66 2e 74 6f 74 61 6c 54 |f'% (sel|f.totalT|
|00001120| 69 6d 65 29 0d 20 20 20 | 20 20 20 63 2e 63 72 65 |ime). | c.cre|
|00001130| 61 74 65 5f 74 65 78 74 | 28 20 73 65 6c 66 2e 6d |ate_text|( self.m|
|00001140| 61 70 47 55 54 54 45 52 | 2c 20 73 65 6c 66 2e 6d |apGUTTER|, self.m|
|00001150| 61 70 47 55 54 54 45 52 | 2c 0d 20 20 20 20 20 20 |apGUTTER|,. |
|00001160| 74 65 78 74 3d 74 6f 74 | 61 6c 54 69 6d 65 53 74 |text=tot|alTimeSt|
|00001170| 72 2c 20 66 6f 6e 74 3d | 66 6f 6e 74 54 69 74 6c |r, font=|fontTitl|
|00001180| 65 2c 20 66 69 6c 6c 3d | 43 4f 4c 4f 52 74 78 33 |e, fill=|COLORtx3|
|00001190| 2c 20 61 6e 63 68 6f 72 | 3d 27 6e 77 27 29 0d 0d |, anchor|='nw')..|
|000011a0| 20 20 20 20 20 20 23 20 | 6b 65 79 20 66 6f 72 20 | # |key for |
|000011b0| 74 69 6d 65 0d 20 20 20 | 20 20 20 6e 6f 50 61 72 |time. | noPar|
|000011c0| 74 69 74 69 6f 6e 73 20 | 3d 20 31 36 2e 30 0d 20 |titions |= 16.0. |
|000011d0| 20 20 20 20 20 6b 65 79 | 57 69 64 74 68 20 20 20 | key|Width |
|000011e0| 20 3d 20 73 65 6c 66 2e | 6d 61 70 57 49 44 54 48 | = self.|mapWIDTH|
|000011f0| 20 2f 20 6e 6f 50 61 72 | 74 69 74 69 6f 6e 73 0d | / noPar|titions.|
|00001200| 20 20 20 20 20 20 78 43 | 75 72 72 65 6e 74 50 6f | xC|urrentPo|
|00001210| 73 20 3d 20 73 65 6c 66 | 2e 78 4d 61 72 67 69 6e |s = self|.xMargin|
|00001220| 53 68 69 66 74 0d 0d 20 | 20 20 20 20 20 66 6f 72 |Shift.. | for|
|00001230| 20 6b 65 79 50 61 72 74 | 69 74 69 6f 6e 20 69 6e | keyPart|ition in|
|00001240| 20 72 61 6e 67 65 28 30 | 2c 6e 6f 50 61 72 74 69 | range(0|,noParti|
|00001250| 74 69 6f 6e 73 29 3a 20 | 20 20 20 20 20 20 20 20 |tions): | |
|00001260| 0d 20 20 20 20 20 20 20 | 20 20 78 53 74 61 72 74 |. | xStart|
|00001270| 20 20 3d 20 78 43 75 72 | 72 65 6e 74 50 6f 73 0d | = xCur|rentPos.|
|00001280| 20 20 20 20 20 20 20 20 | 20 78 45 6e 64 20 20 20 | | xEnd |
|00001290| 20 3d 20 78 43 75 72 72 | 65 6e 74 50 6f 73 20 2b | = xCurr|entPos +|
|000012a0| 20 6b 65 79 57 69 64 74 | 68 0d 20 20 20 20 20 20 | keyWidt|h. |
|000012b0| 20 20 20 79 53 74 61 72 | 74 20 20 3d 20 30 0d 20 | yStar|t = 0. |
|000012c0| 20 20 20 20 20 20 20 20 | 79 45 6e 64 20 20 20 20 | |yEnd |
|000012d0| 3d 20 73 65 6c 66 2e 77 | 69 6e 48 45 49 47 48 54 |= self.w|inHEIGHT|
|000012e0| 0d 0d 20 20 20 20 20 20 | 20 20 20 23 20 63 6f 6d |.. | # com|
|000012f0| 6d 65 6e 74 65 64 20 6f | 75 74 20 70 6f 72 74 69 |mented o|ut porti|
|00001300| 6f 6e 73 20 63 72 65 61 | 74 65 20 66 69 6c 6c 65 |ons crea|te fille|
|00001310| 64 20 72 65 63 74 61 6e | 67 6c 65 73 0d 20 20 20 |d rectan|gles. |
|00001320| 20 20 20 20 20 20 69 66 | 20 6b 65 79 50 61 72 74 | if| keyPart|
|00001330| 69 74 69 6f 6e 20 3d 3d | 20 30 3a 20 23 20 66 69 |ition ==| 0: # fi|
|00001340| 72 73 74 20 6e 65 65 64 | 73 20 74 6f 20 62 65 20 |rst need|s to be |
|00001350| 62 6b 67 20 63 6f 6c 6f | 72 0d 20 20 20 20 20 20 |bkg colo|r. |
|00001360| 20 20 20 20 20 20 63 2e | 63 72 65 61 74 65 5f 6c | c.|create_l|
|00001370| 69 6e 65 28 78 53 74 61 | 72 74 2c 79 53 74 61 72 |ine(xSta|rt,yStar|
|00001380| 74 2c 78 53 74 61 72 74 | 2c 79 45 6e 64 2c 20 66 |t,xStart|,yEnd, f|
|00001390| 69 6c 6c 3d 27 62 6c 61 | 63 6b 27 2c 20 77 69 64 |ill='bla|ck', wid|
|000013a0| 74 68 3d 31 29 0d 20 20 | 20 20 20 20 20 20 20 65 |th=1). | e|
|000013b0| 6c 69 66 20 28 6b 65 79 | 50 61 72 74 69 74 69 6f |lif (key|Partitio|
|000013c0| 6e 20 25 20 32 29 20 3d | 3d 20 30 3a 0d 20 20 20 |n % 2) =|= 0:. |
|000013d0| 20 20 20 20 20 20 20 20 | 20 23 63 2e 63 72 65 61 | | #c.crea|
|000013e0| 74 65 5f 72 65 63 74 61 | 6e 67 6c 65 28 78 53 74 |te_recta|ngle(xSt|
|000013f0| 61 72 74 2c 79 53 74 61 | 72 74 2c 78 45 6e 64 2c |art,ySta|rt,xEnd,|
|00001400| 79 45 6e 64 2c 20 66 69 | 6c 6c 3d 43 4f 4c 4f 52 |yEnd, fi|ll=COLOR|
|00001410| 62 67 35 2c 20 0d 20 20 | 20 20 20 20 20 20 20 20 |bg5, . | |
|00001420| 20 20 23 6f 75 74 6c 69 | 6e 65 3d 27 62 6c 61 63 | #outli|ne='blac|
|00001430| 6b 27 2c 20 77 69 64 74 | 68 3d 30 29 0d 20 20 20 |k', widt|h=0). |
|00001440| 20 20 20 20 20 20 20 20 | 20 63 2e 63 72 65 61 74 | | c.creat|
|00001450| 65 5f 6c 69 6e 65 28 78 | 53 74 61 72 74 2c 79 53 |e_line(x|Start,yS|
|00001460| 74 61 72 74 2c 78 53 74 | 61 72 74 2c 79 45 6e 64 |tart,xSt|art,yEnd|
|00001470| 2c 20 66 69 6c 6c 3d 43 | 4f 4c 4f 52 62 67 32 2c |, fill=C|OLORbg2,|
|00001480| 20 77 69 64 74 68 3d 31 | 29 0d 0d 20 20 20 20 20 | width=1|).. |
|00001490| 20 20 20 20 20 20 20 74 | 69 6d 65 20 3d 20 28 73 | t|ime = (s|
|000014a0| 65 6c 66 2e 74 6f 74 61 | 6c 54 69 6d 65 2f 6e 6f |elf.tota|lTime/no|
|000014b0| 50 61 72 74 69 74 69 6f | 6e 73 29 20 2a 20 6b 65 |Partitio|ns) * ke|
|000014c0| 79 50 61 72 74 69 74 69 | 6f 6e 0d 20 20 20 20 20 |yPartiti|on. |
|000014d0| 20 20 20 20 20 20 20 74 | 69 6d 65 20 3d 20 27 25 | t|ime = '%|
|000014e0| 2e 31 66 27 20 25 20 74 | 69 6d 65 0d 20 20 20 20 |.1f' % t|ime. |
|000014f0| 20 20 20 20 20 20 20 20 | 63 75 72 72 65 6e 74 54 | |currentT|
|00001500| 69 6d 65 20 3d 20 27 25 | 73 27 25 20 28 74 69 6d |ime = '%|s'% (tim|
|00001510| 65 29 0d 20 20 20 20 20 | 20 20 20 20 20 20 20 23 |e). | #|
|00001520| 20 74 68 69 73 20 61 64 | 64 73 20 6e 75 6d 62 65 | this ad|ds numbe|
|00001530| 72 73 20 74 6f 20 6b 65 | 79 0d 20 20 20 20 20 20 |rs to ke|y. |
|00001540| 20 20 20 20 20 20 63 2e | 63 72 65 61 74 65 5f 74 | c.|create_t|
|00001550| 65 78 74 28 20 28 78 43 | 75 72 72 65 6e 74 50 6f |ext( (xC|urrentPo|
|00001560| 73 2b 73 65 6c 66 2e 6d | 61 70 47 55 54 54 45 52 |s+self.m|apGUTTER|
|00001570| 29 2c 20 73 65 6c 66 2e | 6d 61 70 47 55 54 54 45 |), self.|mapGUTTE|
|00001580| 52 2c 0d 20 20 20 20 20 | 20 20 20 20 20 20 20 74 |R,. | t|
|00001590| 65 78 74 3d 63 75 72 72 | 65 6e 74 54 69 6d 65 2c |ext=curr|entTime,|
|000015a0| 20 66 6f 6e 74 3d 66 6f | 6e 74 54 69 74 6c 65 2c | font=fo|ntTitle,|
|000015b0| 20 66 69 6c 6c 3d 43 4f | 4c 4f 52 74 78 33 2c 20 | fill=CO|LORtx3, |
|000015c0| 61 6e 63 68 6f 72 3d 27 | 6e 77 27 29 0d 20 20 20 |anchor='|nw'). |
|000015d0| 20 20 20 20 20 20 20 20 | 20 23 20 0d 20 20 20 20 | | # . |
|000015e0| 20 20 20 20 20 65 6c 73 | 65 3a 0d 20 20 20 20 20 | els|e:. |
|000015f0| 20 20 20 20 20 20 20 23 | 63 2e 63 72 65 61 74 65 | #|c.create|
|00001600| 5f 72 65 63 74 61 6e 67 | 6c 65 28 78 53 74 61 72 |_rectang|le(xStar|
|00001610| 74 2c 79 53 74 61 72 74 | 2c 78 45 6e 64 2c 79 45 |t,yStart|,xEnd,yE|
|00001620| 6e 64 2c 20 66 69 6c 6c | 3d 43 4f 4c 4f 52 62 67 |nd, fill|=COLORbg|
|00001630| 32 2c 20 0d 20 20 20 20 | 20 20 20 20 20 20 20 20 |2, . | |
|00001640| 23 6f 75 74 6c 69 6e 65 | 3d 27 62 6c 61 63 6b 27 |#outline|='black'|
|00001650| 2c 20 77 69 64 74 68 3d | 30 29 0d 20 20 20 20 20 |, width=|0). |
|00001660| 20 20 20 20 20 20 20 63 | 2e 63 72 65 61 74 65 5f | c|.create_|
|00001670| 6c 69 6e 65 28 78 53 74 | 61 72 74 2c 79 53 74 61 |line(xSt|art,ySta|
|00001680| 72 74 2c 78 53 74 61 72 | 74 2c 79 45 6e 64 2c 20 |rt,xStar|t,yEnd, |
|00001690| 66 69 6c 6c 3d 43 4f 4c | 4f 52 62 67 35 2c 20 77 |fill=COL|ORbg5, w|
|000016a0| 69 64 74 68 3d 31 29 0d | 0d 20 20 20 20 20 20 20 |idth=1).|. |
|000016b0| 20 20 78 43 75 72 72 65 | 6e 74 50 6f 73 20 3d 20 | xCurre|ntPos = |
|000016c0| 78 43 75 72 72 65 6e 74 | 50 6f 73 20 2b 20 6b 65 |xCurrent|Pos + ke|
|000016d0| 79 57 69 64 74 68 0d 0d | 0d 20 20 20 20 20 20 23 |yWidth..|. #|
|000016e0| 20 74 65 78 74 75 72 65 | 73 0d 20 20 20 20 20 20 | texture|s. |
|000016f0| 79 50 6f 73 69 74 69 6f | 6e 20 3d 20 73 65 6c 66 |yPositio|n = self|
|00001700| 2e 79 4d 61 72 67 69 6e | 53 68 69 66 74 20 2b 20 |.yMargin|Shift + |
|00001710| 73 65 6c 66 2e 6d 61 70 | 47 55 54 54 45 52 20 23 |self.map|GUTTER #|
|00001720| 20 69 6e 69 74 69 61 6c | 20 73 70 61 63 65 0d 20 | initial| space. |
|00001730| 20 20 20 20 20 73 6f 72 | 74 65 64 54 65 78 74 75 | sor|tedTextu|
|00001740| 72 65 73 20 3d 20 73 65 | 6c 66 2e 74 69 4d 61 70 |res = se|lf.tiMap|
|00001750| 44 69 63 74 2e 6b 65 79 | 73 28 29 0d 20 20 20 20 |Dict.key|s(). |
|00001760| 20 20 73 6f 72 74 65 64 | 54 65 78 74 75 72 65 73 | sorted|Textures|
|00001770| 2e 73 6f 72 74 28 29 0d | 20 20 20 20 20 20 66 6f |.sort().| fo|
|00001780| 72 20 65 6e 74 72 79 20 | 69 6e 20 73 6f 72 74 65 |r entry |in sorte|
|00001790| 64 54 65 78 74 75 72 65 | 73 3a 0d 20 20 20 20 20 |dTexture|s:. |
|000017a0| 20 20 20 20 79 45 6e 64 | 50 6f 73 20 3d 20 79 50 | yEnd|Pos = yP|
|000017b0| 6f 73 69 74 69 6f 6e 20 | 2b 20 73 65 6c 66 2e 77 |osition |+ self.w|
|000017c0| 69 64 74 68 45 6e 74 72 | 79 0d 20 20 20 20 20 20 |idthEntr|y. |
|000017d0| 20 20 20 74 53 74 61 72 | 74 20 20 3d 20 73 65 6c | tStar|t = sel|
|000017e0| 66 2e 74 69 4d 61 70 44 | 69 63 74 5b 65 6e 74 72 |f.tiMapD|ict[entr|
|000017f0| 79 5d 5b 27 74 52 61 6e | 67 65 27 5d 5b 30 5d 0d |y]['tRan|ge'][0].|
|00001800| 20 20 20 20 20 20 20 20 | 20 74 45 6e 64 20 20 20 | | tEnd |
|00001810| 20 3d 20 73 65 6c 66 2e | 74 69 4d 61 70 44 69 63 | = self.|tiMapDic|
|00001820| 74 5b 65 6e 74 72 79 5d | 5b 27 74 52 61 6e 67 65 |t[entry]|['tRange|
|00001830| 27 5d 5b 31 5d 0d 20 20 | 20 20 20 20 20 20 20 78 |'][1]. | x|
|00001840| 53 74 61 72 74 20 20 3d | 20 73 65 6c 66 2e 78 4d |Start =| self.xM|
|00001850| 61 72 67 69 6e 53 68 69 | 66 74 20 2b 20 28 73 65 |arginShi|ft + (se|
|00001860| 6c 66 2e 6d 61 70 57 49 | 44 54 48 20 2a 20 28 74 |lf.mapWI|DTH * (t|
|00001870| 53 74 61 72 74 2f 73 65 | 6c 66 2e 74 6f 74 61 6c |Start/se|lf.total|
|00001880| 54 69 6d 65 29 29 0d 20 | 20 20 20 20 20 20 20 20 |Time)). | |
|00001890| 78 45 6e 64 20 20 20 20 | 3d 20 73 65 6c 66 2e 78 |xEnd |= self.x|
|000018a0| 4d 61 72 67 69 6e 53 68 | 69 66 74 20 2b 20 28 73 |MarginSh|ift + (s|
|000018b0| 65 6c 66 2e 6d 61 70 57 | 49 44 54 48 20 2a 20 28 |elf.mapW|IDTH * (|
|000018c0| 74 45 6e 64 2f 73 65 6c | 66 2e 74 6f 74 61 6c 54 |tEnd/sel|f.totalT|
|000018d0| 69 6d 65 29 29 0d 20 20 | 20 20 20 20 20 20 20 79 |ime)). | y|
|000018e0| 48 65 61 64 53 74 61 72 | 74 20 3d 20 79 50 6f 73 |HeadStar|t = yPos|
|000018f0| 69 74 69 6f 6e 0d 20 20 | 20 20 20 20 20 20 20 79 |ition. | y|
|00001900| 48 65 61 64 45 6e 64 20 | 20 20 3d 20 79 50 6f 73 |HeadEnd | = yPos|
|00001910| 69 74 69 6f 6e 20 2b 20 | 73 65 6c 66 2e 65 6e 74 |ition + |self.ent|
|00001920| 72 79 48 65 61 64 48 65 | 69 67 68 74 0d 20 20 20 |ryHeadHe|ight. |
|00001930| 20 20 20 20 20 20 79 42 | 6f 64 79 53 74 61 72 74 | yB|odyStart|
|00001940| 20 3d 20 79 50 6f 73 69 | 74 69 6f 6e 20 2b 20 73 | = yPosi|tion + s|
|00001950| 65 6c 66 2e 65 6e 74 72 | 79 48 65 61 64 48 65 69 |elf.entr|yHeadHei|
|00001960| 67 68 74 0d 20 20 20 20 | 20 20 20 20 20 79 42 6f |ght. | yBo|
|00001970| 64 79 45 6e 64 20 20 20 | 3d 20 79 45 6e 64 50 6f |dyEnd |= yEndPo|
|00001980| 73 0d 0d 20 20 20 20 20 | 20 20 20 20 63 2e 63 72 |s.. | c.cr|
|00001990| 65 61 74 65 5f 72 65 63 | 74 61 6e 67 6c 65 28 78 |eate_rec|tangle(x|
|000019a0| 53 74 61 72 74 2c 79 48 | 65 61 64 53 74 61 72 74 |Start,yH|eadStart|
|000019b0| 2c 78 45 6e 64 2c 79 48 | 65 61 64 45 6e 64 2c 20 |,xEnd,yH|eadEnd, |
|000019c0| 66 69 6c 6c 3d 43 4f 4c | 4f 52 74 78 31 2c 20 0d |fill=COL|ORtx1, .|
|000019d0| 20 20 20 20 20 20 20 20 | 20 6f 75 74 6c 69 6e 65 | | outline|
|000019e0| 3d 43 4f 4c 4f 52 74 78 | 31 2c 20 77 69 64 74 68 |=COLORtx|1, width|
|000019f0| 3d 30 29 0d 0d 20 20 20 | 20 20 20 20 20 20 69 66 |=0).. | if|
|00001a00| 20 73 65 6c 66 2e 74 69 | 4d 61 70 44 69 63 74 5b | self.ti|MapDict[|
|00001a10| 65 6e 74 72 79 5d 5b 27 | 6d 75 74 65 53 74 61 74 |entry]['|muteStat|
|00001a20| 75 73 27 5d 20 3d 3d 20 | 27 6d 75 74 65 4f 46 46 |us'] == |'muteOFF|
|00001a30| 27 3a 20 23 20 6e 6f 72 | 6d 61 6c 0d 20 20 20 20 |': # nor|mal. |
|00001a40| 20 20 20 20 20 20 20 20 | 63 2e 63 72 65 61 74 65 | |c.create|
|00001a50| 5f 72 65 63 74 61 6e 67 | 6c 65 28 78 53 74 61 72 |_rectang|le(xStar|
|00001a60| 74 2c 79 42 6f 64 79 53 | 74 61 72 74 2c 78 45 6e |t,yBodyS|tart,xEn|
|00001a70| 64 2c 79 42 6f 64 79 45 | 6e 64 2c 20 66 69 6c 6c |d,yBodyE|nd, fill|
|00001a80| 3d 43 4f 4c 4f 52 62 67 | 31 2c 20 0d 20 20 20 20 |=COLORbg|1, . |
|00001a90| 20 20 20 20 20 20 20 20 | 6f 75 74 6c 69 6e 65 3d | |outline=|
|00001aa0| 43 4f 4c 4f 52 62 67 31 | 2c 20 77 69 64 74 68 3d |COLORbg1|, width=|
|00001ab0| 30 29 20 0d 20 20 20 20 | 20 20 20 20 20 65 6c 73 |0) . | els|
|00001ac0| 65 3a 20 23 20 73 69 6c | 65 6e 63 65 64 0d 20 20 |e: # sil|enced. |
|00001ad0| 20 20 20 20 20 20 20 20 | 20 20 63 2e 63 72 65 61 | | c.crea|
|00001ae0| 74 65 5f 72 65 63 74 61 | 6e 67 6c 65 28 78 53 74 |te_recta|ngle(xSt|
|00001af0| 61 72 74 2c 79 42 6f 64 | 79 53 74 61 72 74 2c 28 |art,yBod|yStart,(|
|00001b00| 78 45 6e 64 2d 31 29 2c | 28 79 42 6f 64 79 45 6e |xEnd-1),|(yBodyEn|
|00001b10| 64 2d 31 29 2c 20 0d 20 | 20 20 20 20 20 20 20 20 |d-1), . | |
|00001b20| 20 20 20 66 69 6c 6c 3d | 4e 6f 6e 65 2c 20 6f 75 | fill=|None, ou|
|00001b30| 74 6c 69 6e 65 3d 43 4f | 4c 4f 52 62 67 31 2c 20 |tline=CO|LORbg1, |
|00001b40| 77 69 64 74 68 3d 31 29 | 20 20 20 20 20 20 20 20 |width=1)| |
|00001b50| 20 20 0d 0d 20 20 20 20 | 20 20 20 20 20 63 2e 63 | .. | c.c|
|00001b60| 72 65 61 74 65 5f 74 65 | 78 74 28 73 65 6c 66 2e |reate_te|xt(self.|
|00001b70| 6d 61 70 47 55 54 54 45 | 52 2c 20 28 79 45 6e 64 |mapGUTTE|R, (yEnd|
|00001b80| 50 6f 73 20 2d 20 73 65 | 6c 66 2e 6d 61 70 47 55 |Pos - se|lf.mapGU|
|00001b90| 54 54 45 52 29 2c 20 74 | 65 78 74 3d 65 6e 74 72 |TTER), t|ext=entr|
|00001ba0| 79 2c 20 0d 20 20 20 20 | 20 20 20 20 20 66 6f 6e |y, . | fon|
|00001bb0| 74 3d 66 6f 6e 74 54 69 | 74 6c 65 2c 20 66 69 6c |t=fontTi|tle, fil|
|00001bc0| 6c 3d 43 4f 4c 4f 52 74 | 78 31 2c 20 61 6e 63 68 |l=COLORt|x1, anch|
|00001bd0| 6f 72 3d 27 77 27 29 0d | 20 20 20 20 20 20 20 20 |or='w').| |
|00001be0| 20 23 20 73 68 69 66 74 | 20 64 6f 77 6e 0d 20 20 | # shift| down. |
|00001bf0| 20 20 20 20 20 20 20 79 | 50 6f 73 69 74 69 6f 6e | y|Position|
|00001c00| 20 3d 20 79 45 6e 64 50 | 6f 73 20 2b 20 73 65 6c | = yEndP|os + sel|
|00001c10| 66 2e 6d 61 70 47 55 54 | 54 45 52 0d 20 20 20 20 |f.mapGUT|TER. |
|00001c20| 20 20 20 20 20 0d 20 20 | 20 20 20 20 20 20 20 23 | . | #|
|00001c30| 20 63 6c 6f 6e 65 73 0d | 20 20 20 20 20 20 20 20 | clones.| |
|00001c40| 20 66 6f 72 20 63 6c 6f | 6e 65 4e 61 6d 65 20 69 | for clo|neName i|
|00001c50| 6e 20 73 65 6c 66 2e 74 | 69 4d 61 70 44 69 63 74 |n self.t|iMapDict|
|00001c60| 5b 65 6e 74 72 79 5d 5b | 27 63 6c 6f 6e 65 44 69 |[entry][|'cloneDi|
|00001c70| 63 74 27 5d 2e 6b 65 79 | 73 28 29 3a 0d 20 20 20 |ct'].key|s():. |
|00001c80| 20 20 20 20 20 20 20 20 | 20 79 45 6e 64 50 6f 73 | | yEndPos|
|00001c90| 20 3d 20 79 50 6f 73 69 | 74 69 6f 6e 20 2b 20 73 | = yPosi|tion + s|
|00001ca0| 65 6c 66 2e 77 69 64 74 | 68 45 6e 74 72 79 0d 20 |elf.widt|hEntry. |
|00001cb0| 20 20 20 20 20 20 20 20 | 20 20 20 63 74 53 74 61 | | ctSta|
|00001cc0| 72 74 20 20 3d 20 74 53 | 74 61 72 74 20 2b 20 73 |rt = tS|tart + s|
|00001cd0| 65 6c 66 2e 74 69 4d 61 | 70 44 69 63 74 5b 65 6e |elf.tiMa|pDict[en|
|00001ce0| 74 72 79 5d 5b 27 63 6c | 6f 6e 65 44 69 63 74 27 |try]['cl|oneDict'|
|00001cf0| 5d 5b 63 6c 6f 6e 65 4e | 61 6d 65 5d 0d 20 20 20 |][cloneN|ame]. |
|00001d00| 20 20 20 20 20 20 20 20 | 20 63 74 45 6e 64 20 20 | | ctEnd |
|00001d10| 20 20 3d 20 74 45 6e 64 | 20 20 20 2b 20 73 65 6c | = tEnd| + sel|
|00001d20| 66 2e 74 69 4d 61 70 44 | 69 63 74 5b 65 6e 74 72 |f.tiMapD|ict[entr|
|00001d30| 79 5d 5b 27 63 6c 6f 6e | 65 44 69 63 74 27 5d 5b |y]['clon|eDict'][|
|00001d40| 63 6c 6f 6e 65 4e 61 6d | 65 5d 0d 20 20 20 20 20 |cloneNam|e]. |
|00001d50| 20 20 20 20 20 20 20 78 | 53 74 61 72 74 20 20 3d | x|Start =|
|00001d60| 20 73 65 6c 66 2e 78 4d | 61 72 67 69 6e 53 68 69 | self.xM|arginShi|
|00001d70| 66 74 20 2b 20 28 73 65 | 6c 66 2e 6d 61 70 57 49 |ft + (se|lf.mapWI|
|00001d80| 44 54 48 20 2a 20 0d 20 | 20 20 20 20 20 20 20 20 |DTH * . | |
|00001d90| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 28 63 74 | | (ct|
|00001da0| 53 74 61 72 74 2f 73 65 | 6c 66 2e 74 6f 74 61 6c |Start/se|lf.total|
|00001db0| 54 69 6d 65 29 29 20 0d | 20 20 20 20 20 20 20 20 |Time)) .| |
|00001dc0| 20 20 20 20 78 45 6e 64 | 20 20 20 20 3d 20 73 65 | xEnd| = se|
|00001dd0| 6c 66 2e 78 4d 61 72 67 | 69 6e 53 68 69 66 74 20 |lf.xMarg|inShift |
|00001de0| 2b 20 28 73 65 6c 66 2e | 6d 61 70 57 49 44 54 48 |+ (self.|mapWIDTH|
|00001df0| 20 2a 0d 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | *. | |
|00001e00| 20 20 20 20 20 20 20 20 | 20 28 63 74 45 6e 64 2f | | (ctEnd/|
|00001e10| 73 65 6c 66 2e 74 6f 74 | 61 6c 54 69 6d 65 29 29 |self.tot|alTime))|
|00001e20| 20 0d 20 20 20 20 20 20 | 20 20 20 20 20 20 79 48 | . | yH|
|00001e30| 65 61 64 53 74 61 72 74 | 20 3d 20 79 50 6f 73 69 |eadStart| = yPosi|
|00001e40| 74 69 6f 6e 0d 20 20 20 | 20 20 20 20 20 20 20 20 |tion. | |
|00001e50| 20 79 48 65 61 64 45 6e | 64 20 20 20 3d 20 79 50 | yHeadEn|d = yP|
|00001e60| 6f 73 69 74 69 6f 6e 20 | 2b 20 73 65 6c 66 2e 65 |osition |+ self.e|
|00001e70| 6e 74 72 79 48 65 61 64 | 48 65 69 67 68 74 0d 20 |ntryHead|Height. |
|00001e80| 20 20 20 20 20 20 20 20 | 20 20 20 79 42 6f 64 79 | | yBody|
|00001e90| 53 74 61 72 74 20 3d 20 | 79 50 6f 73 69 74 69 6f |Start = |yPositio|
|00001ea0| 6e 20 2b 20 73 65 6c 66 | 2e 65 6e 74 72 79 48 65 |n + self|.entryHe|
|00001eb0| 61 64 48 65 69 67 68 74 | 0d 20 20 20 20 20 20 20 |adHeight|. |
|00001ec0| 20 20 20 20 20 79 42 6f | 64 79 45 6e 64 20 20 20 | yBo|dyEnd |
|00001ed0| 3d 20 79 45 6e 64 50 6f | 73 0d 20 20 20 0d 0d 20 |= yEndPo|s. .. |
|00001ee0| 20 20 20 20 20 20 20 20 | 20 20 20 63 2e 63 72 65 | | c.cre|
|00001ef0| 61 74 65 5f 72 65 63 74 | 61 6e 67 6c 65 28 78 53 |ate_rect|angle(xS|
|00001f00| 74 61 72 74 2c 79 48 65 | 61 64 53 74 61 72 74 2c |tart,yHe|adStart,|
|00001f10| 78 45 6e 64 2c 79 48 65 | 61 64 45 6e 64 2c 20 0d |xEnd,yHe|adEnd, .|
|00001f20| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 66 | | f|
|00001f30| 69 6c 6c 3d 43 4f 4c 4f | 52 62 67 33 2c 20 6f 75 |ill=COLO|Rbg3, ou|
|00001f40| 74 6c 69 6e 65 3d 43 4f | 4c 4f 52 62 67 33 2c 20 |tline=CO|LORbg3, |
|00001f50| 77 69 64 74 68 3d 30 29 | 0d 0d 20 20 20 20 20 20 |width=0)|.. |
|00001f60| 20 20 20 20 20 20 69 66 | 20 73 65 6c 66 2e 74 69 | if| self.ti|
|00001f70| 4d 61 70 44 69 63 74 5b | 65 6e 74 72 79 5d 5b 27 |MapDict[|entry]['|
|00001f80| 6d 75 74 65 53 74 61 74 | 75 73 27 5d 20 3d 3d 20 |muteStat|us'] == |
|00001f90| 27 6d 75 74 65 4f 46 46 | 27 3a 20 23 20 6e 6f 72 |'muteOFF|': # nor|
|00001fa0| 6d 61 6c 0d 20 20 20 20 | 20 20 20 20 20 20 20 20 |mal. | |
|00001fb0| 20 20 20 63 2e 63 72 65 | 61 74 65 5f 72 65 63 74 | c.cre|ate_rect|
|00001fc0| 61 6e 67 6c 65 28 78 53 | 74 61 72 74 2c 79 42 6f |angle(xS|tart,yBo|
|00001fd0| 64 79 53 74 61 72 74 2c | 78 45 6e 64 2c 79 42 6f |dyStart,|xEnd,yBo|
|00001fe0| 64 79 45 6e 64 2c 20 0d | 20 20 20 20 20 20 20 20 |dyEnd, .| |
|00001ff0| 20 20 20 20 20 20 20 66 | 69 6c 6c 3d 43 4f 4c 4f | f|ill=COLO|
|00002000| 52 62 67 34 2c 20 6f 75 | 74 6c 69 6e 65 3d 43 4f |Rbg4, ou|tline=CO|
|00002010| 4c 4f 52 62 67 34 2c 20 | 77 69 64 74 68 3d 30 29 |LORbg4, |width=0)|
|00002020| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 65 6c 73 |. | els|
|00002030| 65 3a 20 23 20 73 69 6c | 65 6e 63 65 64 0d 20 20 |e: # sil|enced. |
|00002040| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 63 2e 63 | | c.c|
|00002050| 72 65 61 74 65 5f 72 65 | 63 74 61 6e 67 6c 65 28 |reate_re|ctangle(|
|00002060| 78 53 74 61 72 74 2c 79 | 42 6f 64 79 53 74 61 72 |xStart,y|BodyStar|
|00002070| 74 2c 28 78 45 6e 64 2d | 31 29 2c 28 79 42 6f 64 |t,(xEnd-|1),(yBod|
|00002080| 79 45 6e 64 2d 31 29 2c | 20 0d 20 20 20 20 20 20 |yEnd-1),| . |
|00002090| 20 20 20 20 20 20 20 20 | 20 66 69 6c 6c 3d 4e 6f | | fill=No|
|000020a0| 6e 65 2c 20 6f 75 74 6c | 69 6e 65 3d 43 4f 4c 4f |ne, outl|ine=COLO|
|000020b0| 52 62 67 34 2c 20 77 69 | 64 74 68 3d 31 29 20 20 |Rbg4, wi|dth=1) |
|000020c0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 0d 20 20 | | . |
|000020d0| 20 20 20 20 20 20 20 20 | 20 20 23 20 63 6c 6f 6e | | # clon|
|000020e0| 65 20 6c 61 62 65 6c 73 | 20 61 72 65 20 73 68 69 |e labels| are shi|
|000020f0| 66 74 65 64 20 72 69 67 | 68 74 20 61 20 62 69 74 |fted rig|ht a bit|
|00002100| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 63 2e 63 |. | c.c|
|00002110| 72 65 61 74 65 5f 74 65 | 78 74 28 28 73 65 6c 66 |reate_te|xt((self|
|00002120| 2e 6d 61 70 47 55 54 54 | 45 52 2a 34 29 2c 20 28 |.mapGUTT|ER*4), (|
|00002130| 79 45 6e 64 50 6f 73 20 | 2d 20 73 65 6c 66 2e 6d |yEndPos |- self.m|
|00002140| 61 70 47 55 54 54 45 52 | 29 2c 20 0d 20 20 20 20 |apGUTTER|), . |
|00002150| 20 20 20 20 20 20 20 20 | 74 65 78 74 3d 63 6c 6f | |text=clo|
|00002160| 6e 65 4e 61 6d 65 2c 20 | 66 6f 6e 74 3d 66 6f 6e |neName, |font=fon|
|00002170| 74 54 69 74 6c 65 2c 20 | 66 69 6c 6c 3d 43 4f 4c |tTitle, |fill=COL|
|00002180| 4f 52 74 78 32 2c 20 61 | 6e 63 68 6f 72 3d 27 77 |ORtx2, a|nchor='w|
|00002190| 27 29 0d 20 20 20 20 20 | 20 20 20 20 20 20 20 23 |'). | #|
|000021a0| 20 73 68 69 66 74 20 64 | 6f 77 6e 0d 20 20 20 20 | shift d|own. |
|000021b0| 20 20 20 20 20 20 20 20 | 79 50 6f 73 69 74 69 6f | |yPositio|
|000021c0| 6e 20 3d 20 79 45 6e 64 | 50 6f 73 20 2b 20 73 65 |n = yEnd|Pos + se|
|000021d0| 6c 66 2e 6d 61 70 47 55 | 54 54 45 52 0d 0d 20 20 |lf.mapGU|TTER.. |
|000021e0| 20 20 20 20 23 20 6c 61 | 73 74 20 70 61 63 6b 0d | # la|st pack.|
|000021f0| 20 20 20 20 20 20 66 72 | 61 6d 65 2e 70 61 63 6b | fr|ame.pack|
|00002200| 28 65 78 70 61 6e 64 3d | 31 2c 20 66 69 6c 6c 3d |(expand=|1, fill=|
|00002210| 27 62 6f 74 68 27 2c 20 | 70 61 64 79 3d 30 2c 20 |'both', |pady=0, |
|00002220| 70 61 64 78 3d 30 29 0d | 0d 20 20 20 64 65 66 20 |padx=0).|. def |
|00002230| 72 65 69 6e 69 74 28 73 | 65 6c 66 2c 20 6d 61 73 |reinit(s|elf, mas|
|00002240| 74 65 72 2c 20 61 6f 3d | 4e 6f 6e 65 2c 20 62 61 |ter, ao=|None, ba|
|00002250| 72 48 45 49 47 48 54 3d | 39 2c 20 77 69 6e 57 49 |rHEIGHT=|9, winWI|
|00002260| 44 54 48 3d 37 30 30 29 | 3a 0d 20 20 20 20 20 20 |DTH=700)|:. |
|00002270| 73 65 6c 66 2e 5f 5f 69 | 6e 69 74 5f 5f 28 6d 61 |self.__i|nit__(ma|
|00002280| 73 74 65 72 2c 20 61 6f | 3d 4e 6f 6e 65 2c 20 62 |ster, ao|=None, b|
|00002290| 61 72 48 45 49 47 48 54 | 3d 39 2c 20 77 69 6e 57 |arHEIGHT|=9, winW|
|000022a0| 49 44 54 48 3d 37 30 30 | 29 0d 0d 20 20 20 64 65 |IDTH=700|).. de|
|000022b0| 66 20 66 69 6e 64 54 6f | 74 61 6c 54 69 6d 65 28 |f findTo|talTime(|
|000022c0| 73 65 6c 66 2c 20 74 69 | 4d 61 70 44 69 63 74 29 |self, ti|MapDict)|
|000022d0| 3a 0d 20 20 20 20 20 20 | 6d 61 78 54 69 6d 65 20 |:. |maxTime |
|000022e0| 3d 20 30 2e 30 0d 20 20 | 20 20 20 20 66 6f 72 20 |= 0.0. | for |
|000022f0| 74 69 4e 61 6d 65 20 69 | 6e 20 74 69 4d 61 70 44 |tiName i|n tiMapD|
|00002300| 69 63 74 2e 6b 65 79 73 | 28 29 3a 0d 20 20 20 20 |ict.keys|():. |
|00002310| 20 20 20 20 20 73 74 61 | 72 74 54 69 6d 65 20 3d | sta|rtTime =|
|00002320| 20 74 69 4d 61 70 44 69 | 63 74 5b 74 69 4e 61 6d | tiMapDi|ct[tiNam|
|00002330| 65 5d 5b 27 74 52 61 6e | 67 65 27 5d 5b 30 5d 0d |e]['tRan|ge'][0].|
|00002340| 20 20 20 20 20 20 20 20 | 20 65 6e 64 54 69 6d 65 | | endTime|
|00002350| 20 3d 20 74 69 4d 61 70 | 44 69 63 74 5b 74 69 4e | = tiMap|Dict[tiN|
|00002360| 61 6d 65 5d 5b 27 74 52 | 61 6e 67 65 27 5d 5b 31 |ame]['tR|ange'][1|
|00002370| 5d 0d 20 20 20 20 20 20 | 20 20 20 69 66 20 6d 61 |]. | if ma|
|00002380| 78 54 69 6d 65 20 3c 3d | 20 65 6e 64 54 69 6d 65 |xTime <=| endTime|
|00002390| 3a 0d 20 20 20 20 20 20 | 20 20 20 20 20 20 6d 61 |:. | ma|
|000023a0| 78 54 69 6d 65 20 3d 20 | 65 6e 64 54 69 6d 65 0d |xTime = |endTime.|
|000023b0| 20 20 20 20 20 20 20 20 | 20 66 6f 72 20 63 6c 6f | | for clo|
|000023c0| 6e 65 4e 61 6d 65 20 69 | 6e 20 74 69 4d 61 70 44 |neName i|n tiMapD|
|000023d0| 69 63 74 5b 74 69 4e 61 | 6d 65 5d 5b 27 63 6c 6f |ict[tiNa|me]['clo|
|000023e0| 6e 65 44 69 63 74 27 5d | 2e 6b 65 79 73 28 29 3a |neDict']|.keys():|
|000023f0| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 63 6c 6f |. | clo|
|00002400| 6e 65 45 6e 64 54 69 6d | 65 20 3d 20 74 69 4d 61 |neEndTim|e = tiMa|
|00002410| 70 44 69 63 74 5b 74 69 | 4e 61 6d 65 5d 5b 27 63 |pDict[ti|Name]['c|
|00002420| 6c 6f 6e 65 44 69 63 74 | 27 5d 5b 63 6c 6f 6e 65 |loneDict|'][clone|
|00002430| 4e 61 6d 65 5d 20 2b 20 | 65 6e 64 54 69 6d 65 0d |Name] + |endTime.|
|00002440| 20 20 20 20 20 20 20 20 | 20 20 20 20 69 66 20 6d | | if m|
|00002450| 61 78 54 69 6d 65 20 3c | 3d 20 63 6c 6f 6e 65 45 |axTime <|= cloneE|
|00002460| 6e 64 54 69 6d 65 3a 0d | 20 20 20 20 20 20 20 20 |ndTime:.| |
|00002470| 20 20 20 20 20 20 20 6d | 61 78 54 69 6d 65 20 3d | m|axTime =|
|00002480| 20 63 6c 6f 6e 65 45 6e | 64 54 69 6d 65 0d 20 20 | cloneEn|dTime. |
|00002490| 20 20 20 20 72 65 74 75 | 72 6e 20 28 6d 61 78 54 | retu|rn (maxT|
|000024a0| 69 6d 65 20 2b 20 30 2e | 30 29 20 23 20 6d 61 6b |ime + 0.|0) # mak|
|000024b0| 65 20 61 20 66 6c 6f 61 | 74 0d 0d 0d 64 65 66 20 |e a floa|t...def |
|000024c0| 64 72 61 77 28 62 61 72 | 48 45 49 47 48 54 3d 39 |draw(bar|HEIGHT=9|
|000024d0| 2c 20 77 69 6e 57 49 44 | 54 48 3d 37 30 30 29 3a |, winWID|TH=700):|
|000024e0| 0d 20 20 20 72 6f 6f 74 | 20 3d 20 54 6b 28 29 0d |. root| = Tk().|
|000024f0| 20 20 20 23 20 72 6f 6f | 74 20 69 73 20 74 68 65 | # roo|t is the|
|00002500| 20 6d 61 73 74 65 72 20 | 6f 66 20 74 68 69 73 20 | master |of this |
|00002510| 63 6c 61 73 73 0d 20 20 | 20 41 4f 6d 61 70 20 3d |class. | AOmap =|
|00002520| 20 41 4f 6d 61 70 43 61 | 6e 76 61 73 28 72 6f 6f | AOmapCa|nvas(roo|
|00002530| 74 2c 20 4e 6f 6e 65 2c | 20 62 61 72 48 45 49 47 |t, None,| barHEIG|
|00002540| 48 54 2c 20 77 69 6e 57 | 49 44 54 48 29 0d 20 20 |HT, winW|IDTH). |
|00002550| 20 72 6f 6f 74 2e 74 69 | 74 6c 65 28 27 54 49 6d | root.ti|tle('TIm|
|00002560| 61 70 27 29 0d 20 20 20 | 72 6f 6f 74 2e 69 63 6f |ap'). |root.ico|
|00002570| 6e 6e 61 6d 65 28 27 54 | 49 6d 61 70 27 29 0d 20 |nname('T|Imap'). |
|00002580| 20 20 72 6f 6f 74 2e 6d | 61 78 73 69 7a 65 28 77 | root.m|axsize(w|
|00002590| 69 64 74 68 3d 41 4f 6d | 61 70 2e 77 69 6e 57 49 |idth=AOm|ap.winWI|
|000025a0| 44 54 48 2c 20 68 65 69 | 67 68 74 3d 41 4f 6d 61 |DTH, hei|ght=AOma|
|000025b0| 70 2e 77 69 6e 48 45 49 | 47 48 54 29 0d 20 20 20 |p.winHEI|GHT). |
|000025c0| 72 6f 6f 74 2e 6d 69 6e | 73 69 7a 65 28 77 69 64 |root.min|size(wid|
|000025d0| 74 68 3d 41 4f 6d 61 70 | 2e 77 69 6e 57 49 44 54 |th=AOmap|.winWIDT|
|000025e0| 48 2c 20 68 65 69 67 68 | 74 3d 41 4f 6d 61 70 2e |H, heigh|t=AOmap.|
|000025f0| 77 69 6e 48 45 49 47 48 | 54 29 0d 20 20 20 72 6f |winHEIGH|T). ro|
|00002600| 6f 74 2e 6d 61 69 6e 6c | 6f 6f 70 28 29 0d 0d 0d |ot.mainl|oop()...|
|00002610| 0d 69 66 20 5f 5f 6e 61 | 6d 65 5f 5f 20 3d 3d 20 |.if __na|me__ == |
|00002620| 27 5f 5f 6d 61 69 6e 5f | 5f 27 3a 0d 20 20 20 72 |'__main_|_':. r|
|00002630| 6f 6f 74 20 3d 20 54 6b | 28 29 0d 20 20 20 41 4f |oot = Tk|(). AO|
|00002640| 6d 61 70 20 3d 20 41 4f | 6d 61 70 43 61 6e 76 61 |map = AO|mapCanva|
|00002650| 73 28 72 6f 6f 74 29 0d | 20 20 20 72 6f 6f 74 2e |s(root).| root.|
|00002660| 74 69 74 6c 65 28 27 54 | 49 6d 61 70 27 29 0d 20 |title('T|Imap'). |
|00002670| 20 20 72 6f 6f 74 2e 69 | 63 6f 6e 6e 61 6d 65 28 | root.i|conname(|
|00002680| 27 54 49 6d 61 70 27 29 | 0d 20 20 20 72 6f 6f 74 |'TImap')|. root|
|00002690| 2e 6d 61 78 73 69 7a 65 | 28 77 69 64 74 68 3d 41 |.maxsize|(width=A|
|000026a0| 4f 6d 61 70 2e 77 69 6e | 57 49 44 54 48 2c 20 68 |Omap.win|WIDTH, h|
|000026b0| 65 69 67 68 74 3d 41 4f | 6d 61 70 2e 77 69 6e 48 |eight=AO|map.winH|
|000026c0| 45 49 47 48 54 29 0d 20 | 20 20 72 6f 6f 74 2e 6d |EIGHT). | root.m|
|000026d0| 69 6e 73 69 7a 65 28 77 | 69 64 74 68 3d 41 4f 6d |insize(w|idth=AOm|
|000026e0| 61 70 2e 77 69 6e 57 49 | 44 54 48 2c 20 68 65 69 |ap.winWI|DTH, hei|
|000026f0| 67 68 74 3d 41 4f 6d 61 | 70 2e 77 69 6e 48 45 49 |ght=AOma|p.winHEI|
|00002700| 47 48 54 29 0d 20 20 20 | 72 6f 6f 74 2e 6d 61 69 |GHT). |root.mai|
|00002710| 6e 6c 6f 6f 70 28 29 0d | 00 00 00 00 00 00 00 00 |nloop().|........|
|00002720| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002730| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002740| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002750| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002760| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002770| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002780| 00 00 01 00 00 00 01 00 | 00 00 00 00 00 00 00 1e |........|........|
|00002790| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000027a0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000027b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000027c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000027d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000027e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000027f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002800| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002810| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002820| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002830| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002840| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002850| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002860| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002870| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002880| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002890| 00 00 00 00 00 00 00 00 | 00 1c 00 1e ff ff 00 00 |........|........|
|000028a0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000028b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000028c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000028d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000028e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000028f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+